import request from "@/utils/request";

// 查询仓库其他费用台账列表
export function listWarehouseOtherCost(query) {
  return request({
    url: "/cost/warehouseOtherCost/list",
    method: "get",
    params: query,
  });
}

// 查询仓库其他费用台账所有列表
export function listAllWarehouseOtherCost(query) {
  return request({
    url: "/cost/warehouseOtherCost/listAll",
    method: "get",
    params: query,
  });
}

// 查询仓库其他费用台账详细
export function getWarehouseOtherCost(id) {
  return request({
    url: "/cost/warehouseOtherCost/getInfo/" + id,
    method: "get",
  });
}

// 新增仓库其他费用台账
export function addWarehouseOtherCost(data) {
  return request({
    url: "/cost/warehouseOtherCost/add",
    method: "post",
    data: data,
  });
}

// 修改仓库其他费用台账
export function updateWarehouseOtherCost(data) {
  return request({
    url: "/cost/warehouseOtherCost/edit",
    method: "post",
    data: data,
  });
}

// 删除仓库其他费用台账
export function delWarehouseOtherCost(id) {
  return request({
    url: "/cost/warehouseOtherCost/remove/" + id,
    method: "get",
  });
}

// 获取项目总含税金额
export function getAmountTotal(ledgerTypeId, projectId) {
  return request({
    url: "/cost/warehouseOtherCost/getAmountTotal",
    method: "get",
    params: {
      ledgerTypeId,
      projectId,
    },
  });
}
